Using cross-entropy to test executable logic code

ABSTRACT

A method for detecting the occurrence of rare events in an executable logic code includes assigning a first probability of a chance of traversal of one or more decision paths, in which each path connects two decision points defined by execution of the logic code. As a result of execution of the logic code, the decision paths traversed are evaluated to determine whether said traversal conforms to a predefined performance function. The performance function defines a goal to be achieved pursuant to the execution of the logic code. A second probability is assigned to the chance of traversal of at least one of said one or more decision paths to increase the likelihood that the one or more decision paths are traversed in a subsequent execution of the logic code in a closer conformity with the predefined performance function.

COPYRIGHT & TRADEMARK NOTICES

A portion of the disclosure of this patent document contains material,which is subject to copyright protection. The owner has no objection tothe facsimile reproduction by any one of the patent document or thepatent disclosure, as it appears in the Patent and Trademark Officepatent file or records, but otherwise reserves all copyrightswhatsoever.

Certain marks referenced herein may be common law or registeredtrademarks of third parties affiliated or unaffiliated with theapplicant or the assignee. Use of these marks is for providing anenabling disclosure by way of example and shall not be construed tolimit the scope of this invention to material associated with suchmarks.

TECHNICAL FIELD

The present invention relates generally to testing large programs and,more particularly, to a method for testing large programs using across-entropy scheme.

BACKGROUND

Exhaustive testing of a commercially written program code that hasthousands of lines of codes and multitudes of execution paths is verychallenging, particularly when there are a large number of nested loopsand conditional branches (i.e., interleavings) in the logic code.

Complex programs are commonly tested by way of non-exhaustive testingmethods, such has simulation and verification. Simulation andverification techniques are generally based on a heuristic approachwhich is efficient in determining most errors in typical programs, butdoes not guarantee discovery of all errors (i.e., bugs).Simulation-based verification is traditionally used to verify thecorrectness of a program with respect to a set of input values.Different input values can induce a different execution path for theprogram under test.

Execution of a program in a certain path is considered to be correct, ifthe program behaves as required (i.e., produces the expected output) forall possible input values for that path. Ideally, a completeverification will test all execution paths in a program, using allpossible input values for each path. Obviously, this approach is verytime consuming and expensive, if not impractical.

A more practical testing option focuses on discovering bugs thatmanifest themselves when the computing system is subjected to a heavycomputational load during runtime (i.e., stress-testing). Anotherpractical approach involves creating random interference in an eventscheduler which leads to randomized interleavings in execution paths.

The interference is created by injecting noise to the scheduler forcingthe scheduler to create uncommon interleavings, which are rare duringusual execution. However, a chance of finding a very rare bug or adefective program routine that is only very rarely initiated is small,since the random distribution created by injecting noise cannot beadjusted to a specific pattern.

The most commonly used method to maximize the exhaustiveness of testingis coverage estimation. There is an extensive simulation-basedverification research on coverage metrics, which provides a measure fordetermining the exhaustiveness of a test. Coverage metrics are used inorder to monitor progress of the verification process, estimate whethermore input sequences are needed, and whether direct simulation towardsunexplored areas of the program are required.

In the related art systems, the metrics measure the part of the designthat has been activated by the input sequences. For example, code-basedcoverage metrics measure the number of code lines executed during thesimulation. There is a variety of different metrics used in coverageestimation, and they play an important role in the design validationeffort. Still, since there is no special effort directed to a possiblyerroneous pattern in the code, rare bugs can remain undetected evenafter testing has reached a high degree of coverage.

Thus, software testing and verification methods and systems are neededthat can overcome the aforementioned shortcomings by directing codetesting according to performance measures that enhance identification ofbugs, especially those of the rare event type.

SUMMARY

The present invention is directed to systems, methods and correspondingproducts that facilitate testing and verification of large programs.

For purposes of summarizing, certain aspects, advantages, and novelfeatures of the invention have been described herein. It is to beunderstood that not all such advantages may be achieved in accordancewith any one particular embodiment of the invention. Thus, the inventionmay be embodied or carried out in a manner that achieves or optimizesone advantage or group of advantages without achieving all advantages asmay be taught or suggested herein.

In accordance with one embodiment, a method for testing and verificationof large programs is provided. The method comprises determining theexistence of a program bug that rarely manifests itself by executing theprogram many times where, in each execution, the path selection betweendecision nodes, scheduling and delay are updated based on whether thedistribution of the generated results conform to a predefinedperformance function. The performance function is utilized to measurethe outcome of each test execution based on maximizing the occurrence ofa rare event that constitutes a hard to discover error in the programduring normal execution. When the performance function distributionnarrows below a selected statistical deviation in successive runs, suchthat further iteration adds little new information, the test isconsidered completed.

If each decision point in the program under test is represented by anode, an execution path (or edge) represents the route from one node tothe next. A decision point is a point in the execution where the nextaction is chosen among two or more possible actions, due to concurrency,different inputs, or otherwise non-deterministic decisions. Theprobability of execution for each path at a node can be defined byvalues stored in a probability distribution table. Initially, a uniformrandom or equal chance of execution may be assigned to each path atvarious nodes. Thereafter, a cross-entropy method may be used to updatethe probability of execution for each path to optimize occurrence of therare event, according to a predetermined performance function thatprovides a measure for how the result of execution in each path conformsto the goal defined by the performance function.

In accordance with one embodiment, a method for detecting the occurrenceof rare events in an executable logic code comprises assigning a firstprobability of a chance of traversal of one or more decision paths, inwhich each path connects two decision points defined by execution of alogic code. The one or more decision paths traversed and the output areevaluated as a result of execution of the logic code, to determinewhether said traversal conforms to a predefined performance function.The predefined performance function defines a goal to be achievedpursuant to the execution of the logic code. A second probability isassigned to the chance of traversal of at least one of said one or moredecision paths to increase the likelihood that the one or more decisionpaths are traversed in a subsequent execution of the logic code in acloser conformity with the predefined performance function.

In accordance with one aspect of the invention, a computer programproduct comprising a computer useable medium having a computer readableprogram is provided. The computer readable program when executed on acomputer causes the computer to perform the functions and operationsassociated with the above-disclosed methods. In yet another embodiment,a system comprising one or more logic units is provided. The one or morelogic units are configured to perform the functions and operationsassociated with the above-disclosed methods.

In an exemplary embodiment, a system for detecting the occurrence ofrare events in an executable logic code comprises a logic unit forexecuting the logic code under test, and a logic unit for monitoring theexecution progress. The system may further comprise an initializer forassigning a first probability of a chance of traversal to one or moredecision paths, in which each path connects two decision points definedby execution of the logic code; an evaluator for evaluating one or moredecision paths traversed, as a result of execution of the logic code, todetermine whether said traversal conforms to a predefined performancefunction.

The exemplary embodiment may further comprise an updater to calculate asecond probability of the chance of traversal of at least one of saidone or more decision paths to increase the likelihood that the one ormore decision paths are traversed in a subsequent execution of the logiccode in a closer conformity with the predefined performance function;and a decider that chooses the next path to run according to the currentprobability of the chance of traversal of at least one of said one ormore decision paths, and provides a mutual exclusion condition noticeconcerning the execution of two or more paths of the logic code undertest.

In certain exemplary embodiments, the system may also comprise aninstumentor for implementing callbacks at synchronization points of thelogic code under test; and a stopper that obtains a mutual exclusioncondition for each executable path based on the callbacks from theinstumentor.

One or more of the above-disclosed embodiments in addition to certainalternatives are provided in further detail below with reference to theattached figures. The invention is not, however, limited to anyparticular embodiment disclosed.

BRIEF DESCRIPTION OF THE DRAWINGS

Embodiments of the present invention are understood by referring to thefigures in the attached drawings, as provided below.

FIG. 1 is a block diagram of a system for testing programs, inaccordance with one embodiment.

FIG. 2 is a flow diagram of a method for testing programs, in accordancewith one embodiment.

FIG. 3 is an execution graph corresponding to exemplary execution pathstraversed as the result of execution of the logic code illustrated inTable 1.

Features, elements, and aspects of the invention that are referenced bythe same numerals in different figures represent the same, equivalent,or similar features, elements, or aspects, in accordance with one ormore embodiments.

DETAILED DESCRIPTION OF EXEMPLARY EMBODIMENTS

The present disclosure is directed to systems and corresponding methodsthat facilitate testing large programs, preferably using a cross-entropyscheme.

In the following, numerous specific details are set forth to provide athorough description of various embodiments. Certain embodiments may bepracticed without these specific details or with some variations indetail. In some instances, certain features are described in less detailso as not to obscure other aspects of the invention. The level of detailassociated with each of the elements or features should not be construedto qualify the novelty or importance of one feature over the others.

Referring to FIG. 1, system 100 comprises hardware and softwarecomponents for testing a program in conformity with a performancefunction as provided in further detail below. As shown, a controlprogram 115 is configured to monitor a logic code under test (hereaftertest code) 110. A first logic unit 120 may be provided for executingtest code 110, and a second logic unit 130 for running control program115 to monitor the execution progress of test code 110. Depending onimplementation, the first and second logic units 120, 130 may beimplemented in a single or more than two logic units, for example.Memory 140 may be also provided for storing at least one of test code110, control program 115, and data generated during the execution oftest code 110.

Test code 110 may be implemented such that, when executed, one or moredecision points (i.e., nodes) are encountered. At each node, a decisionis made to branch out via one or more paths (i.e., edges) to other nodesin test code 110. Decisions are made at each node concerning which pathto follow. In one embodiment, execution of test code 110 involves theconcurrent processing of several threads where, in accordance with oneembodiment, control program 115 is implemented to control executionprogress of test code 110 and measure characteristics of the resultingexecution paths to determine the degree of conformance of the results toa predetermined performance function.

The performance function may be configured to provide guidance forsearching for executions path that result in rare occurrences based on aprobability distribution assigned to each path at a node. Theprobability distribution for available paths in each node may beevaluated based on the conformity of results with a performance functionaccording to a cross-entropy scheme. Cross-entropy is a technique highlyadapted to rare event simulation and is used for identifying the pathsto an event with a very small probability of occurrence. A rare event isan event that does not occur very often when choices are made randomlyat each decision point during the execution of a program.

As provided in further detail below, cross-entropy is preferably used tominimize the number of executions needed to converge on a set ofexecution paths during execution of test code 110. That is,cross-entropy helps to rapidly reduce the difference between successiveprobability distributions for various paths in order to rapidly convergeon the behavior of test code 110 toward a closer conformity with theperformance function.

Referring back to FIG. 1, control program 115 may be configured toupdate the probability for traversal of different paths at each node toencourage rapid convergence toward execution paths that satisfy or moreclosely conform to the performance function. Accordingly, controlprogram 115 is configured to amplify the likelihood of triggering rareoccurrences and revealing the conditions under which such occurrencesmay take place by monitoring and influencing the execution paths chosenduring the various iterations for test code 110.

In an exemplary embodiment, control program 115 may comprise aninitializer 150, an evaluator 160, an updater 170, a decider 180, aninstrumentor 190 and a stopper 195. Said components of control program115 may be implemented in form of software, hardware or a combinationthereof depending on implementation. Initializer 150 provides input andassigns a first probability distribution for traversal of various pathsat each node during execution of test code 110. The probabilitydistribution for each path may be stored in a probability distributiontable 175. Depending on implementation, the initial probabilitydistribution for each path may be, for example, equally divided amongall paths for each node. Alternatively, the probability distribution maybe unequally divided among different paths according to a predetermineddistribution factor.

Evaluator 160 is configured to evaluate one or more decision pathstraversed during execution of test code 110 to determine whether thepath traversal conforms to a predefined performance function. Updater170 may be configured to update the probability distribution fortraversal of one or more of paths available at a node during subsequentexecutions of test code 110. Probability distribution values for one ormore paths may be stored in memory 140 in a probability distributiontable 175, for example, corresponding to the execution history of testcode 110.

Probability distribution assigned to a path at a node defines thelikelihood for choosing that path over another at the respective node,if that node is traversed during execution of test code 110. Forexample, based on the results obtained by evaluator 160, a certain pathat a selected node may be assigned a low (e.g., zero) probability ofexecution, thus effectively reducing (or eliminating) the chance thatthe first path will be selected during the next execution.Alternatively, a second path at the same node may be assigned anamplified (e.g., 100%) likelihood of execution, thus enhancing (orguaranteeing) the chances that said path is selected during the nexttest execution.

The probability of execution for some paths in a node may be higher,when the assigned probability for execution of another path for the samenode has been reduced. For example, where the assigned probability isdistributed among two paths as 50-50, if the probability for one isreduced to 25%, the probability for the other may be enhanced to 75%. Byupdating and adjusting the probability distribution for different pathsat each node, control program 115 provides an approach conducive to therapid convergence of the behavior of test code 110 towards executionresults that are advantageously in closer conformity with a predefinedperformance function at each subsequent execution.

Based on probability distribution generated by updater 170, decider 180may select the paths that will be executed during the next execution,while instrumentor 190 implements callbacks at synchronization points oftest code 110. Stopper 195 may obtain mutually exclusive conditions foreach executable path based on the callbacks from instrumentor 190. Forexample, on a call from instrumentor 190, stopper 195 may allow decider180 to choose the path to be executed. If the path selected by decider180 is not the one called, stopper 195 may delay the execution of theselected path. In one embodiment, stopper 195 is configured to determinewhich path may be executed at an instance of execution of test code 110,based on callbacks provided by instrumentor 190.

FIG. 2 is a flow diagram of a method 200 for testing an exemplary logiccode (e.g., test code 110), in accordance with one embodiment. Referringto FIGS. 1 and 2, initializer 150 assigns a probability to one or moreexecution paths for one or more nodes in test code 110 (S210). As notedearlier, the assigned probability value to each path identifies thechance of traversal for that path in relation to other possible pathsthat may be available for traversal at a node in test code 110. Duringan initialization process, the assigned probability may be equallydivided among all paths in a node. For example, in a node where fourdecision paths may be traversed, the assigned probability to each pathmay be 25%.

After providing a selected input and assigning the probabilitydistribution to one or more paths in test code 110, initializer 150executes test code 110 (S 220). Execution of test code 110 generates anexecution path history and an output corresponding to the providedinput. Evaluator 160 evaluates execution results for each traversed pathrelative to a performance function (S230). Evaluator 160 determineswhether the execution results conform to a predefined threshold for theperformance function.

The performance function defines a goal to be achieved pursuant to theexecution of test code 110. The predetermined threshold is reached whenupdating the distribution probability for the paths in subsequentexecutions will likely not lead to a closer conformity of the resultswith the performance function. Evidence that conformity is achieved maybe demonstrated by a stable distribution in the execution resultsobtained during further execution of test code 110. For example, ifevaluator 160 detects that the statistical distribution of outputresults, obtained from successive execution of test code 110, arenarrower than a predetermined threshold (e.g., maximum spread) then itis determined that a closer conformity with the performance function maynot be achieve regardless of how many more times test code 110 isexecuted.

If the execution results do not conform to the predetermined threshold,updater 170 may update the probability of execution for one or morepaths in one or more nodes of test case 110 in order to increase thelikelihood that the one or more decision paths are traversed in asubsequent execution of test code 110 in closer conformity with thepredefined performance function (S250). In some embodiments, updater 170performs the updating function in accordance with values stored inprobability distribution table 175 by decider 180. Decider 180 assignsthe probability distribution value according to results provided byevaluator 160 to improve the subsequent results of execution of testcode 110 in closer conformity with the predefined performance function.

In an exemplary embodiments, a cross-entropy scheme is utilized toselect some percentage (e.g., approximately 15%) of best samplesgenerated as the result of execution of test code 110, according to theconformity of such samples to the performance function. In such exampleembodiment, updater 170 may update values in probability distributiontable 175 to imitate the parameters that generated the best samples.This approach minimizes the cross-entropy divergence between theprevious distribution and the one which encompasses the selectedsamples.

Once updater 170 has updated probability distribution table 175, controlsoftware 115 continues to monitor execution of test code 110 accordingto the updated probability distribution values, and to evaluate theresult; and if needed update the values in probability distributiontable 175 (S220-S250) until evaluator 160 determines that the executionresults conform to the predetermined threshold for the predefinedperformance function. If so, then control program 115 outputs theexecution results for test code 110 for further evaluation by anindependent decision maker, such as a human operator, for example(S260).

The above method can be used to focus the executions on patterns forwhich reasonable metrics can be defined. The following is a partial listof patterns or potential bugs which may be tested using thecross-entropy scheme:

-   -   1. Buffer Overflow: The number of the messages in a buffer, with        respect to the buffer's maximum capacity, can be used for        detecting buffer overflow problems.    -   2. Deadlock: The number of locks simultaneously taken and not        released during execution can be used for detecting deadlocks.    -   3. Rare Data: The number of shared resources accessed on an        execution path can be used for detecting rare data races.    -   4. Several Consecutive Errors: The number of error paths (e.g.,        throw exceptions) executed can be used for detecting bugs or        leaks which appear only in extreme situations of several        consecutive errors.    -   5. Synchronization Primitives: The number of mutually exclusive        functions traversed in an execution path can be used to reveal        bugs caused by bad understanding of the synchronization        primitives.    -   6. Wait Notify: The number of lost notifies can be used to find        wait-notify bugs.    -   7. Task Failures or Cancellations: The number of canceled        threads or tasks can be used to detect bad recovery from task        failures and cancellations.

Table 1 blow is an example of a control program for detecting bufferoverflow problems, according to one embodiment. The numbers on the leftare the line numbers and they appear in the nodes of FIG. 3, which is adiagram illustrating the possible paths traversed during execution of anexample test code 110 based on the exemplary control program in Table 1.Under testing conditions, the paths taken from (1,1) to (30,30) may bepruned using cross-entropy according to method 200 to force theoccurrence of a rare event, such rare event in this example being abuffer overflow.

TABLE 1 Example test code - Stack Overflow with A and B threads Theoriginal code of each thread: 1: stopper.startThreadCB(this); 2: myName= getName( ); 3:  for(int i=0;i<2;i++) 4:  { 5:  stopper.lockCB(this);6:   { 7:   // check top of stack - if it is not myName then push: 8:  if (next == 0 || !data[next−1].equals(myName)) 9:    ret =push(myName); 10:    else 11:     pop( ); 12:   } 13: stopper.unlockCB(this); 14:  } 15: stopper.endThreadCB(this);=================================== The same code in unwound form: 1: stopper.startThreadCB(this); 2:  myName = getName( ); 3: i=0; 4:  if(i<2) 5:   { 6:   stopper.lockCB(this); 7:   { 8:   // check top ofstack - if it is not myName then push: 9:   if (next == 0 ||!data[next−1].equals(myName)) 10:    ret = push(myName); 11:    else 12:    pop( ); 13:   } 14:   stopper.unlockCB(this); 15:   i++; 16:   if(i<2) 17:   { 18:   stopper.lockCB(this); 19:    { 20:    // check topof stack - if it is not myName then push: 21:    if (next == 0 ||!data[next−1].equals(myName)) 22:      ret = push(myName); 23:    else24:     pop( ); 25:   } 26:   stopper.unlockCB(this); 27:   i++ 28:   }29:  } 30: stopper.endThreadCB(this);

In the above example, the result obtained may show that the number ofelements stored in a buffer elements have surpassed a target threshold.If such results are obtained, then it is an indication a bug isdiscovered and needs to be fixed. Advantageously, bugs can be discoveredat a quicker pace using the cross-entropy method discussed above incomparison to random testing, because at each execution the results arefocused on testing those scenarios that are more likely to create acertain result (e.g., buffer overflow), instead of starting with anequal random probability every time the test is run again.

In different embodiments, the systems and methods disclosed herein canbe implemented either entirely in the form of hardware or entirely inthe form of software, or a combination of both hardware and softwareelements. For example, system 100 may comprise a controlled computingsystem environment that can be presented largely in terms of hardwarecomponents and software code executed to perform processes that achievethe results contemplated by the system of the present disclosure.

A computing environment in accordance with an exemplary embodiment maybe composed of a hardware environment and a software environment. Thehardware environment comprises the machinery and equipment that providean execution environment for the software; and the software provides theexecution instructions for the hardware as provided above.

As provided here, the software elements that are executed on theillustrated hardware elements are described in terms of specificlogical/functional relationships. It should be noted, however, that therespective methods implemented in software may be also implemented inhardware by way of configured and programmed processors, ASICs(application specific integrated circuits), FPGAs (Field ProgrammableGate Arrays) and DSPs (digital signal processors), for example.

In an alternative embodiment, the invention may be implemented ascomputer program product accessible from a computer-usable orcomputer-readable medium providing program code for use by or inconnection with a computer or any instruction execution system. For thepurposes of this description, a computer-usable or computer-readablemedium can be any apparatus that can contain, store, communicate,propagate or transport the program for use by or in connection with theinstruction execution system, apparatus or device.

The computer-readable medium can be an electronic, magnetic, optical,electromagnetic, infrared, or semiconductor system (or apparatus ordevice) or a propagation medium. Examples of a computer-readable mediuminclude a semiconductor or solid-state memory, magnetic tape, aremovable computer diskette, a random access memory (RAM), a read-onlymemory (ROM), a rigid magnetic disk and an optical disk. Currentexamples of optical disks include compact disk read only memory(CD-ROM), compact disk read/write (CD-R/W) and digital videodisk (DVD).

Therefore, it should be understood that the invention can be practicedwith modification and alteration within the spirit and scope of theappended claims. The description is not intended to be exhaustive or tolimit the invention to the precise form disclosed. These and variousother adaptations and combinations of the embodiments disclosed arewithin the scope of the invention and are further defined by the claimsand their full scope of equivalents.

1. A method implemented for execution on one or more controllers fordetecting the occurrence of rare events in an executable logic code, themethod comprising: assigning a first probability of a chance oftraversal of one or more decision paths, in which each path connects twodecision points defined by execution of a logic code; evaluating one ormore decision paths traversed, as a result of execution of the logiccode, to determine whether said traversal conforms to a predefinedperformance function, wherein the performance function defines a goal tobe achieved pursuant to the execution of the logic code; and assigning asecond probability to the chance of traversal of at least one of saidone or more decision paths to increase the likelihood that the one ormore decision paths are traversed in a subsequent execution of the logiccode in a closer conformity with the predefined performance function. 2.The method of claim 1, further comprising continuing to evaluate one ormore decision paths traversed after subsequent executions of the logicto determine whether said traversal more closely conforms to a goalvalue determined by the predefined performance function.
 3. The methodof claim 1, further comprising continuing to update the probabilityassociated with the chance of traversal of said one or more decisionpaths until it is determined that further updating of said probabilityin subsequent executions will likely not lead to a closer conformitywith a goal value defined by the predefined performance function.
 4. Themethod of claim 1, wherein the first probability is almost the same foreach of said one or more decision paths.
 5. The method of claim 1,wherein the second probability enhances the chance of traversal forthose paths that result in a higher conformity with a goal value definedby the predefined performance function.
 6. The method of claim 1,wherein the performance function is a measure for occurrence of a rareevent resulting from the execution of the program code.
 7. The method ofclaim 1, wherein a cross-entropy technique is applied to minimize numberof executions needed for results of execution of the program code toconform to a goal value defined by the performance function at apredetermined level.
 8. The method of claim 1, wherein assigning thesecond probability causes a smaller number of paths to be traversed toachieve a closer conformity with the performance function.
 9. A systemfor detecting the occurrence of rare events in an executable logic code,the system comprising: a logic unit for executing the logic code undertest; a logic unit for running a control program to monitor theexecution progress of the logic code under test, wherein the controlprogram determines whether decision paths traversed, as a result ofexecution of the logic code, conform to a predefined performancefunction, wherein the performance function defines a goal to be achievedpursuant to the execution of the logic code; a memory storage forstoring the logic code under test, the control program for monitoringthe execution of the logic code under test, and data obtained by thecontrol program during execution of the logic code under test.
 10. Thesystem of claim 9, wherein the control program comprises: an initializerfor assigning a first probability of a chance of traversal of one ormore decision paths, in which each path connects two decision pointsdefined by execution of a logic code; an evaluator for evaluating one ormore decision paths traversed, as a result of execution of the logiccode, to determine whether said traversal conforms to a predefinedperformance function, wherein the performance function defines a goal tobe achieved pursuant to the execution of the logic code; and an updaterto calculate a second probability of the chance of traversal of at leastone of said one or more decision paths to increase the likelihood thatthe one or more decision paths are traversed in a subsequent executionof the logic code in a closer conformity with the predefined performancefunction.
 11. The system of claim 9, further comprising a decider thatchooses the next path to run according to the current probability of thechance of traversal of at least one of said one or more decision paths,and provides a mutual exclusion condition notice concerning theexecution of two or more paths of the logic code under test.
 12. Thesystem of claim 11, further comprising an instumentor for implementingcallbacks at synchronization points of the logic code under test; and astopper that obtains a mutual exclusion condition for each executablepath based on the callbacks from the instrumentor.
 13. The system ofclaim 9, wherein the first logic unit and the second logic unit are thesame logic unit.
 14. A computer program product comprising anon-transitory computer useable medium having a computer readableprogram, wherein the computer readable program when executed on acomputer causes the computer to: assign in a second program under test afirst probability of a chance of traversal of one or more decisionpaths, in which each path connects two decision points defined byexecution of a logic code; evaluate one or more decision paths traversedin the second program, as a result of execution of the logic code, todetermine whether said traversal conforms to a predefined performancefunction, wherein the performance function defines a goal to be achievedpursuant to the execution of the logic code; and assign in the secondprogram under test a second probability to the chance of traversal of atleast one of said one or more decision paths to increase the likelihoodthat the one or more decision paths are traversed in a subsequentexecution of the logic code in a closer conformity with the predefinedperformance function.
 15. The computer product of claim 14, furtheradapted to continue to evaluate in the second program under test one ormore decision paths traversed after subsequent executions of the logicto determine whether said traversal more closely conforms to thepredefined performance function.
 16. The computer product of claim 14,further adapted to continue to update in the second program under testthe probability associated with the chance of traversal of said one ormore decision paths until it is determined that further updating of saidprobability in subsequent executions will likely not lead to a closerconformity with the predefined performance function.
 17. The computerproduct of claim 14, further adapted to assign the first probabilitysuch that it is almost the same for each of said one or more decisionpaths.
 18. The computer product of claim 14, further adapted to assignthe second probability to enhance the chance of traversal for thosepaths that result in a higher conformity with the predefined performancefunction.
 19. The computer product of claim 14, wherein the performancefunction is further adapted to measure the occurrence of a rare eventresulting from the execution of the program code in the second programunder test.
 20. The computer product of claim 14, wherein across-entropy technique is applied to minimize the number of executionsneeded of the second program under test for results of execution of theprogram code to conform with the performance function at a predeterminedlevel.